package com.kayt.cyberBar.cyber.business.entity.po;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import javax.persistence.*;


/**
 * The persistent class for the b_cyber_base_order database table.
 * 
 */
@Entity
@Table(name="b_cyber_base_order")
@NamedQuery(name="BCyberBaseOrder.findAll", query="SELECT b FROM BCyberBaseOrder b")
public class BCyberBaseOrder implements Serializable {
	private static final long serialVersionUID = 1L;
	private Long id;
	private String addr;
	private String addrCode;
	private String code;
	private String searchKey;
	private String createTime;
	private String cyberCode;
	private String typeCode;
	private String payType;
	private String price;
	private String ownerCode;
	private String ownerName;
	private String statusCode;
	private String updateTime;
	private String standardTime;
	private String confirmTime;
	private String usedTime;
	private String overed;
	private String reminded;
	private String remarks;
	private String favourName;
	private String favourCode;
	
	private List<BCyberBaseOrderItem> itemList = new ArrayList<>();
	private List<BCyberBaseOrderProduct> productList = new ArrayList<>();

	public BCyberBaseOrder() {
	}


	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}


	public String getAddr() {
		return this.addr;
	}

	public void setAddr(String addr) {
		this.addr = addr;
	}
	@Column(name="FAVOUR_NAME")
	public String getFavourName() {
		return favourName;
	}


	public void setFavourName(String favourName) {
		this.favourName = favourName;
	}

	@Column(name="FAVOUR_CODE")
	public String getFavourCode() {
		return favourCode;
	}


	public void setFavourCode(String favourCode) {
		this.favourCode = favourCode;
	}


	@Column(name="OWNER_CODE")
	public String getOwnerCode() {
		return ownerCode;
	}


	public void setOwnerCode(String ownerCode) {
		this.ownerCode = ownerCode;
	}

	@Column(name="SEARCH_KEY")
	public String getSearchKey() {
		return searchKey;
	}


	public void setSearchKey(String searchKey) {
		this.searchKey = searchKey;
	}


	@Column(name="OWNER_NAME")
	public String getOwnerName() {
		return ownerName;
	}


	public void setOwnerName(String ownerName) {
		this.ownerName = ownerName;
	}


	@Column(name="ADDR_CODE")
	public String getAddrCode() {
		return this.addrCode;
	}

	public void setAddrCode(String addrCode) {
		this.addrCode = addrCode;
	}


	public String getCode() {
		return this.code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	@Column(name="STANDARD_TIME")
	public String getStandardTime() {
		return standardTime;
	}


	public void setStandardTime(String standardTime) {
		this.standardTime = standardTime;
	}

	@Column(name="CONFIRM_TIME")
	public String getConfirmTime() {
		return confirmTime;
	}


	public void setConfirmTime(String confirmTime) {
		this.confirmTime = confirmTime;
	}

	@Column(name="USED_TIME")
	public String getUsedTime() {
		return usedTime;
	}


	public void setUsedTime(String usedTime) {
		this.usedTime = usedTime;
	}


	public String getOvered() {
		return overed;
	}


	public void setOvered(String overed) {
		this.overed = overed;
	}


	public String getReminded() {
		return reminded;
	}


	public void setReminded(String reminded) {
		this.reminded = reminded;
	}


	@Column(name="CREATE_TIME")
	public String getCreateTime() {
		return this.createTime;
	}

	public void setCreateTime(String createTime) {
		this.createTime = createTime;
	}
	

	@Column(name="PAY_TYPE")
	public String getPayType() {
		return payType;
	}


	public void setPayType(String payType) {
		this.payType = payType;
	}


	@Column(name="CYBER_CODE")
	public String getCyberCode() {
		return this.cyberCode;
	}

	public void setCyberCode(String cyberCode) {
		this.cyberCode = cyberCode;
	}

	
	@Column(name="TYPE_CODE")
	public String getTypeCode() {
		return typeCode;
	}


	public void setTypeCode(String typeCode) {
		this.typeCode = typeCode;
	}


	public String getPrice() {
		return this.price;
	}

	public void setPrice(String price) {
		this.price = price;
	}


	public String getRemarks() {
		return remarks;
	}


	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}


	@Column(name="STATUS_CODE")
	public String getStatusCode() {
		return this.statusCode;
	}

	public void setStatusCode(String statusCode) {
		this.statusCode = statusCode;
	}


	@Column(name="UPDATE_TIME")
	public String getUpdateTime() {
		return this.updateTime;
	}

	public void setUpdateTime(String updateTime) {
		this.updateTime = updateTime;
	}


	@OneToMany(targetEntity = BCyberBaseOrderItem.class, cascade = CascadeType.ALL, fetch = FetchType.LAZY, orphanRemoval = true, mappedBy = "order")
	public List<BCyberBaseOrderItem> getItemList() {
		return itemList;
	}


	public void setItemList(List<BCyberBaseOrderItem> itemList) {
		this.itemList = itemList;
	}


	@OneToMany(targetEntity = BCyberBaseOrderProduct.class, cascade = CascadeType.ALL, fetch = FetchType.LAZY, orphanRemoval = true, mappedBy = "order")
	public List<BCyberBaseOrderProduct> getProductList() {
		return productList;
	}


	public void setProductList(List<BCyberBaseOrderProduct> productList) {
		this.productList = productList;
	}

}